﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using System.Threading;
using System.Globalization;
using System.Resources;
namespace MultiLanguage
{
    public partial class WebForm2 : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }
        protected override void InitializeCulture()
        {
            if (Session["MyLanguage"] != null)
            {
                string language = Session["MyLanguage"].ToString();
                Thread.CurrentThread.CurrentCulture=CultureInfo.CreateSpecificCulture(language);
                Thread.CurrentThread.CurrentUICulture=new CultureInfo(language);
            }
        }
        protected void Button1_Click(object sender, EventArgs e)
        {
            Response.Redirect("newsite.aspx");
        }
    }
}